import request from "@/utils/request2";

const BASE_URL = "/api/v1/virtual-number/provider";

const ProviderAPI = {
  getList(params: any) {
    return request({
      url: `${BASE_URL}/list`,
      method: "get",
      params
    });
  },
  getCount(params: any) {
    return request({
      url: `${BASE_URL}/count`,
      method: "get",
      params
    });
  },
  delete(name: string) {
    return request({
      url: `${BASE_URL}/delete/${name}`,
      method: "post",
    });
  },
  update(data: any, name: string) {
    return request({
      url: `${BASE_URL}/update/${name}`,
      method: "post",
      data
    });
  },
  uischema(name: string) {
    return request({
      url: `${BASE_URL}/uischema/${name}`,
      method: "get",
    });
  }
};

export default ProviderAPI;
